<template>
  <div class="conditions-wrapper">
    <div class="conditions-wrapper__item">
      <span class="nick">昵称</span>
      <el-input v-model="user.nick" class="el-Style" placeholder="昵称" @blur="lsblur()" />
    </div>
    <div class="conditions-wrapper__item">
      <span class="subject">所属学科</span>
      <el-select v-model="value" class="el-Style" placeholder="请选择">
        <el-option
          v-for="item in options"
          :key="item.value"
          :label="item.label"
          :value="item.value"
        />
      </el-select>
    </div>
    <div class="conditions-wrapper__item">
      <span class="job">职位</span>
      <el-input v-model="user.job" class="el-Style" placeholder="职位" />
    </div>
    <div class="conditions-wrapper__item">
      <span class="year">工作年限</span>
      <el-input v-model="user.startTime" class="el-Style el-Style1 el-wid1" placeholder="起" />
      <el-input v-model="user.endTime" class="el-Style el-wid1" placeholder="止" />
    </div>
    <div class="conditions-wrapper__item">
      <span class="phone">手机号</span>
      <el-input v-model="user.phone" class="el-Style" placeholder="手机号" />
    </div>
    <el-button class="el-wid2" type="primary" icon="el-icon-search">搜索</el-button>
    <el-button class="el-wid2" type="info" icon="el-icon-huifu-copy iconfont">重置</el-button>
  </div>
</template>

<script>
import { myMixin } from '../../mixin/checkoutRules'

export default {
  mixins: [myMixin],
  data() {
    return {
      options: [{
        value: 'math',
        label: '数学'
      },
      {
        value: 'english',
        label: '英语'
      }],
      value: '',
      user: {
        nick: '',
        job: '',
        startTime: '',
        endTime: '',
        phone: ''
      }
    }
  },
  methods: {
    lsblur() {
      this.validate(this.user)
    }
  }
}
</script>

<style lang="scss" scoped>
.conditions-wrapper{
    display: flex;
    align-content: center;
    width:100%;
    font-weight: bold;
    font-size: 14px;
    color:#666;
    &__item{
        display: flex;
        flex-direction: row;
        align-items: center;
        border-radius: 5px;
        margin-right: 20px;
        span{
            display: inline-block;
            border: 1px solid rgb(231, 231, 231);
            border-radius: 5px 0px 0px 5px;
            border-right: none;
            height: 40px;
            line-height: 40px;
            text-align: center;
        }
    }
}

.nick{
  width: 50px;
}
.job{
  width:50px;
}
.subject{
  width: 80px;
}
.year{
  width:80px;
}
.phone{
  width:70px;
}

.el-wid1{
  width: 70px;
}
</style>
<style>
  .el-Style .el-input__inner{
    border-radius: 0px 5px 5px 0px;

  }
  .el-Style1 .el-input__inner{
    border-radius: 0px;
  }
  .el-wid1 .el-input__inner{
    width: 70px;
    margin: 0px;
  }
  .el-wid1{
    margin: 0px;
  }
  .el-wid2 {
    width: 80px;
    text-align: center;
    height: 40px;
    margin-left: 20px;
  }

</style>
